<?php

namespace App\Library\Logic;

use App\Models\UserAccountModel;
use Illuminate\Database\Eloquent\Builder;
use Illuminate\Database\Eloquent\Model;

class UserAccountLogic extends UserAccountModel
{
    /**
     * 检查提现账户信息
     * @param $data
     * @return Model|Builder|null
     *
     */
    public function check($data): Model|Builder|null
    {
        return self::query()
            ->where([
                'user_id' => USERID,
                'payment_method_id' => $data->payment_method_id,
            ])->first();
    }
}
